class Solution:
    def defangIPaddr(self, address: str) -> str:
        ans=list()
        for i in list(address):
            if i =='.':
                ans.append('[.]')
            else:ans.append(i)
        return "".join(ans) 